Signal coding and decoding methods and devices

ABSTRACT

In a signal coding method, bits for coding allocated to different bands of a frequency domain signal obtained from an input signal are adjusted to improve the coding quality. The total available bits for coding are first allocated to the bands of the frequency domain signal according to a predetermined allocation rule. The numbers of bits allocated to the respective bands of the frequency domain signal are then adjusted when a highest frequency of the frequency domain signal to which bits are allocated is greater than a predetermined value. The frequency domain signal is coded according to the adjusted bit allocation for the bands of the frequency domain signal.

CROSS-REFERENCE TO RELATED APPLICATION

This application is a continuation of U.S. patent application Ser. No.14/496,986, filed on Sep. 25, 2014, which is a continuation ofInternational Application No. PCT/CN2012/075924, filed on May 23, 2012.The International application claims priority to Chinese PatentApplication No. 201210087702.9, filed on Mar. 29, 2012, all of which arehereby incorporated by reference in their entireties.

TECHNICAL FIELD

Embodiments of the present disclosure relate to the communicationsfield, and in particular, to methods and devices for signal coding anddecoding.

BACKGROUND

In the field of communications such as mobile communications and fiberoptic communications, a coding technology is used at a transmit end tocompress a signal to be transmitted, so as to improve the transmissionefficiency, and a corresponding decoding technology is used at a receiveend to restore the transmitted signal. According to a characteristic, atransmission condition, and the like of a signal, time domain codingand/or frequency domain coding may be performed on the signal. Differentbits for coding are allocated to a time domain signal or a frequencydomain signal according to a certain rule, and then the signal is codedaccording to the allocated bits using a coding method. To improve thesignal transmission efficiency, it is expected that a signal to betransmitted is represented using as few bits for coding as possible.Therefore, the bits for coding need to be allocated properly, so thatoutput signals are restored with least distortion at the receive endusing decoding.

In an existing coder for an audio signal, when a code rate is low, acoding and decoding effect may generally be good for speech, but thecoding and decoding effect is poor for music. To improve the quality ofthe music when the code rate is low, an input signal is coded using somebits and using a time domain coding method; and a frequency domainsignal is obtained according to the input signal, and the frequencydomain signal is coded using rest bits and using a frequency domaincoding method. When the frequency domain signal is coded using the restbits, a feature of the signal is generally not considered, and bitallocation is uniformly performed on the frequency domain signal, whichleads to a poor coding effect for some frequency domain signals. In anexisting decoder for an audio signal, the frequency domain signal isrestored by simply using the decoding technology corresponding to thecoding technology, noise is filled into a frequency domain signal thatis not obtained by decoding, and then frequency domain inversetransformation and time domain synthesis processing are performed toobtain the output signal. Extra noise is introduced when the noise isfilled into some signals, which reduces the quality of the outputsignal.

Therefore, an existing solution of performing uniform bit allocation ina frequency domain coding algorithm leads to a poor coding effect forsome signals; and the foregoing noise filling processing in an existingfrequency domain decoding algorithm reduces the quality of the outputsignal.

SUMMARY

Embodiments of the present disclosure provide signal coding and decodingmethods and devices, where, during coding, bit allocation for afrequency domain signal can be optimized, so as to achieve a bettercoding effect using the same number of bits, and during decoding, afrequency domain excitation signal can be extended under the guidance ofinformation obtained by frequency domain decoding, so as to achieve abetter effect of an output signal.

According to one aspect, a signal coding method is provided, where themethod includes obtaining a frequency domain signal according to aninput signal; allocating predetermined bits to the frequency domainsignal according to a predetermined allocation rule; adjusting the bitallocation for the frequency domain signal when a highest frequency ofthe frequency domain signal to which bits are allocated is greater thana predetermined value; and coding the frequency domain signal accordingto the bit allocation for the frequency domain signal.

According to another aspect, a signal decoding method is provided, wherethe method includes obtaining, from a received bit stream, a frequencydomain signal obtained by decoding; when the frequency domain signalobtained by decoding meets a predetermined condition, predicting,according to the frequency domain signal obtained by decoding, afrequency domain signal that is not obtained by decoding; and obtaining,according to the frequency domain signal obtained by decoding and thepredicted frequency domain signal, a time domain signal that is finallyoutputted.

According to still another aspect, a signal coding device is provided,where the device includes a frequency domain transformation unit, whichobtains a frequency domain signal according to an input signal; a bitallocation unit, which allocates predetermined bits to the frequencydomain signal according to a predetermined allocation rule; a bitadjustment unit, which adjusts the bit allocation for the frequencydomain signal when a highest frequency of the frequency domain signal towhich bits are allocated is greater than or equal to a predeterminedvalue; and a frequency domain coding unit, which codes the frequencydomain signal according to the bit allocation for the frequency domainsignal.

According to still another aspect, a signal decoding device is provided,where the device includes a decoding unit, which obtains, from areceived bit stream, a frequency domain signal obtained by decoding; abandwidth extension unit configured to predict a frequency domain signalthat is not obtained by decoding, and when the frequency domain signalobtained by decoding meets a predetermined condition, predict, accordingto the frequency domain signal obtained by decoding, the frequencydomain signal that is not obtained by decoding; and an output unit,which obtains, according to the frequency domain signal obtained bydecoding and the predicted frequency domain signal, a time domain signalthat is finally outputted.

In the foregoing technical solutions of the embodiments of the presentdisclosure, during coding, bit allocation for a frequency domain signalis adjusted according to a highest frequency of the frequency domainsignal to which bits are allocated, so that a better coding effect isachieved when frequency domain coding is performed using the same numberof bits; and during decoding, a frequency domain signal that is notobtained by decoding is set under the guidance of the frequency domainsignal obtained by decoding, so as to achieve a better effect of anoutput signal.

BRIEF DESCRIPTION OF DRAWINGS

To describe the technical solutions in the embodiments of the presentdisclosure more clearly, the following briefly introduces accompanyingdrawings required for describing the embodiments or the prior art. Theaccompanying drawings in the following description show merely someembodiments of the present disclosure.

FIG. 1 shows a signal coding method according to an embodiment of thepresent disclosure;

FIG. 2 shows a time-frequency joint coding method using a coding methodin an embodiment of the present disclosure;

FIG. 3 shows a signal decoding method according to an embodiment of thepresent disclosure;

FIG. 4 shows a method for obtaining, from a received bit stream, afrequency domain signal obtained by decoding in a time-frequency jointdecoding method;

FIG. 5 shows exemplary implementation of a coding device and/or adecoding device according to the present disclosure;

FIG. 6 shows a coding signal coding device according to an embodiment ofthe present disclosure;

FIG. 7 shows a time-frequency joint coding device using a coding devicein an embodiment of the present disclosure;

FIG. 8 shows a signal decoding device according to an embodiment of thepresent disclosure; and

FIG. 9 shows a block diagram of a decoding unit in time-frequency jointdecoding.

DESCRIPTION OF EMBODIMENTS

The following clearly describes the technical solutions in embodimentsof the present disclosure with reference to accompanying drawings in theembodiments of the present disclosure. The described embodiments are apart of the embodiments of the present disclosure rather than all of theembodiments.

A coding technical solution and a decoding technical solution in thepresent disclosure may be applied to sending and receiving in variouscommunications systems, where the communications systems are, forexample, a Global System for Mobile Communications (GSM), a CodeDivision Multiple Access (CDMA) system, Wideband Code Division MultipleAccess (WCDMA), a General Packet Radio Service (GPRS), and Long TermEvolution (LTE).

The coding technical solution and the decoding technical solution arewidely applied to various electronic devices, for example, a mobilephone, a wireless apparatus, a personal data assistant (PDA), a handheldor portable computer, a global positioning system (GPS)receiver/navigator, a camera, an audio/video player, a video camera, avideo recorder, a monitoring device, and the like. Generally, this typeof electronic device includes an audio coder or an audio decoder, wherethe audio coder or decoder may be directly implemented by a digitalcircuit or a chip, for example, a digital signal processor (DSP), or beimplemented by that software code drives a processor to perform aprocedure in the software code.

As an example, in an audio coding technical solution, first, an audiotime domain signal is transformed into a frequency domain signal, then abit for coding is allocated to the audio frequency domain signal forcoding, a coded signal is transmitted to a decoding end using acommunications system, and the coded signal is decoded at the decodingend to restore the frequency domain signal.

FIG. 1 shows a signal coding method 100 according to an embodiment ofthe present disclosure. As shown in FIG. 1, the method includes thefollowing steps.

Step 110: Obtain a frequency domain signal according to an input signal.The input signal may be of various types, such as an image signal, adata signal, an audio signal, a video signal, or a text signal.Frequency domain transformation may be performed on the input signalusing an algorithm such as a fast Fourier transform (FFT) or a discretecosine transform (DCT), to obtain the frequency domain signal. The typeof the input signal and the frequency domain transformation algorithm donot constitute a limitation to the present disclosure.

Step 120: Allocate predetermined bits to the frequency domain signalaccording to a predetermined allocation rule. The predetermined bitstot_bit are bits that need to be used for performing frequency domaincoding on the frequency domain signal. The predetermined allocationrule, for example, may be that more bits in the predetermined bits areallocated to a low frequency band signal in the frequency domain signal,and rest bits in the predetermined bits are allocated to a frequencyband with greater energy except the low frequency band signal. The morebits may be uniformly allocated to the low frequency band signal for alllow frequency bands or the more bits may be allocated to the lowfrequency band signal according to energy distribution of the lowfrequency band signal. A reason for allocating the more bits to the lowfrequency band signal is that, in a speech/audio signal or the like, thelow frequency band signal generally includes information more sensitiveto a human ear.

The following uses frequency domain coding of an audio signal as anexample for description. During the frequency domain coding, thefrequency domain signal is generally divided into sub-bands at an equalinterval according to frequencies, or is divided into sub-bandsaccording to frequency domain coefficients, for example, is divided intoone sub-band every 16 frequency domain coefficients. For example, for awideband signal whose frame length is 20 milliseconds (ms), 160coefficients in a frequency range of 0 to 4 kilohertz (kHz) are dividedinto 10 sub-bands, where there are 5 sub-bands in a frequency range of 0to 2 kHz, and there are 5 sub-bands in a frequency range of 2 to 4 kHz.Then, bit allocation is performed for each sub-band. The more bits whosequantity is 1F_bit are allocated to a low frequency domain signal in thefrequency range of 0 to 2 kHz, the number rest_bit of the rest bits isobtained by subtracting 1F_bit from the number tot_bit of thepredetermined bits, and the rest bits rest_bit are allocated to thesub-bands in the frequency range of 2 to 4 kHz according to an envelopesize of each sub-band in the frequency range of 2 to 4 kHz, where eachsub-band has 5 bits. The number of sub-bands to which bits are allocatedand a sub-band last_bin of a highest frequency band to which bits areallocated are determined according to the rest_bits and the envelopesize of each sub-band, and at the same time, a remainder that cannot beexactly divided by 5 is evenly allocated to each sub-band in the rangeof 0 to 2 kHz.

Step 130: Adjust the bit allocation for the frequency domain signal whena highest frequency of the frequency domain signal to which bits areallocated is greater than a predetermined value B. The predeterminedvalue B may be set according to an empirical value; in an embodiment,the predetermined value B may be determined according to the bit numbertot_bit of the predetermined bits and a resolution of the frequencydomain signal (for example, there are 320 frequency domain coefficientsin a bandwidth range of 0 to 8 kHz). In the case of a fixed bandwidth, alarger bit number tot_bit of the predetermined bits indicates a largerpredetermined value B; and when the bit number tot_bit of thepredetermined bits is fixed, a higher resolution of the frequency domainsignal indicates a larger predetermined value B. When a bandwidth isfixed and the resolution of the frequency domain signal is also fixed,the predetermined value B may be determined only according to the bitnumber tot_bit of the predetermined bits, and a larger bit numbertot_bit of the predetermined bits indicates a larger predetermined valueB. The predetermined value B is a preset upper-limit frequency value.For example, it is estimated according to experience that, after thefrequency domain transformation is performed on the input signal,generally no bit is allocated to a frequency domain signal whosefrequency is greater than the predetermined value. Therefore, inspecific practice, the predetermined value B may be set to a frequencyvalue that is a certain frequency less than a value of the highestfrequency of the frequency domain signal, for example, set to 2.9 kHz,3.2 kHz, 3.5 kHz, or the like. In another embodiment, the predeterminedvalue B may also be determined according to another factor such as aframe length, a used transformation method, or a transformation windowlength.

When the frequency domain signal is divided into sub-bands for coding,the predetermined value B may be an index number of 20 sub-bands in afrequency range of 0 to 8 kHz, and the highest frequency of thefrequency domain signal to which bits are allocated may also berepresented using an index number of a sub-band in which the highestfrequency is located. For example, for a wideband signal whose samplingrate is 16 kHz, a frame length is 20 ms; if a transmission rate is 6.8kbps, B is set to 6 according to the total number (20) of sub-bands andthe number of predetermined bits to be allocated (6.8 kbps×20 ms=136bits); and when the transmission rate is 7.6 kbps, B is set to 8according to the total number (20) of the sub-bands and the number ofpredetermined bits to be allocated (7.6 kbps×20 ms=152 bits). Insummary, the predetermined value B and the highest frequency of thefrequency domain signal to which bits are allocated are not limited tofrequency numerical values, and may also be the index numbers of thesub-bands. After reading a disclosure of the embodiments of the presentdisclosure, an engineering technical person knows, according to apractical condition, how to determine whether the highest frequency ofthe frequency domain signal to which bits are allocated is greater thanthe predetermined value.

The following describes adjustment of the bit allocation for thefrequency domain signal. According to a type, a frequency domaincharacteristic, or the like of a signal, bits, in the frequency domainsignal, of a part that contributes less to an output at a decoding endmay be subtracted, and bits allocated to the highest frequency to whichbits are allocated and its nearby frequency domain signal mayaccordingly be increased. That is, the adjusting the bit allocation forthe frequency domain signal may include reducing the number of bitsallocated to a frequency band to which more bits are allocated in thefrequency domain signal, and increasing the number of bits allocated tothe highest frequency to which bits are allocated and its nearbyfrequency domain signal. For an audio signal, the frequency band towhich more bits are allocated is a low frequency band of 0 to 2 kHz. Thefollowing describes, using examples, adjustment of the bit allocationfor the frequency domain signal.

An adjustment example 1: The highest frequency to which bits areallocated is 4 kHz. If 0 bit is allocated to a sub-band in a range of 2kHz to 4 kHz, 5 bits are allocated to this frequency band until thenumber of bits is allocated to all sub-bands in the range of 2 kHz to 4kHz. It is assumed that the number of bits additionally added in therange of 2 to 4 kHz is N_(bit). In this case, N_(bit) bits need to besubtracted from the sub-bands in the range of 0 to 2 kHz. For example, aused algorithm is that: 1 bit is subtracted from each sub-band in allsub-bands (5 sub-bands) in the range of 0 to 2 kHz, and then a sub-bandwith the highest frequency is reduced; and 1 bit is subtracted againfrom each sub-band in the rest 4 sub-bands, and a sub-band with thesecond highest frequency is reduced again, and the rest is deduced byanalogy until the number of bits that are subtracted is equal toN_(bit).

An adjustment example 2: J bits are added to all sub-bands to which bitsare allocated in the range of 2 kHz to 4 kHz; and it is assumed that thenumber of sub-bands to which bits are allocated in the range of 2 to 4kHz is K; in this case, the number N_(bit) of bits additionally added inthe range of 2 to 4 kHz is equal to J×K, and N_(bit)=J×K bits need to besubtracted from the sub-bands in the range of 0 to 2 kHz. For example,the algorithm that may be used is that: N_(bit)/5 bits are subtracted onaverage from each sub-band in all sub-bands (5 sub-bands) in the rangeof 0 to 2 kHz.

An adjustment example 3: 5 bits are allocated to each sub-band to whichthe number of bits is not allocated in the range of 2 kHz to 4 kHz; thenJ bits are added to all sub-bands in the range of 2 to 4 kHz; if thenumber of sub-bands to which bits are allocated in the range of 2 to 4kHz is K, in this case, the number N_(bit) of bits additionally added inthe range of 2 to 4 kHz is equal to 5×(5−K)+5×J, and N_(bit) bits needto be subtracted from the sub-bands in the range of 0 to 2 kHz. A usedalgorithm may be any one of the algorithm in the adjustment example 1and the algorithm in the adjustment example 2.

In addition, if the highest frequency of the frequency domain signal towhich bits are allocated is less than the predetermined value, theallocation of the predetermined bits that is performed according to thepredetermined allocation rule in 120 is maintained.

Step 140: Code the frequency domain signal according to the bitallocation that has been adjusted. In practice, any frequency domaincoding method may be used according to a requirement. The selectedfrequency domain coding method does not constitute a limitation to thepresent disclosure.

Using the foregoing signal coding method, bit allocation for a frequencydomain signal is adjusted according to a highest frequency of thefrequency domain signal to which bits are allocated, so that a bettercoding effect is achieved when frequency domain coding is performedusing the same number of bits.

The foregoing signal coding method may be properly applied to variouscoding solutions, and the following uses an application of the method intime-frequency joint coding as an example for exemplary description.

FIG. 2 shows a time-frequency joint coding method 200 according to anembodiment of the present disclosure. In FIG. 2, steps 220, 230, and 240are respectively the same as steps 120, 130, and 140 in FIG. 1.Differences between FIG. 2 and FIG. 1 lie in that, step 250 and step 260are added, and step 110 in FIG. 1 is replaced by steps 211 and 212. Thefollowing describes the differences between FIG. 2 and FIG. 1, and doesnot describe the content in common again.

Step 211: Obtain a first time domain signal and a second time domainsignal by performing a time domain analysis on an input signal. Forexample, a linear predictive coding (LPC) analysis and processing areperformed on the input signal to obtain one of a line spectral frequency(LSF) parameter and an immittance spectral frequency (ISF) parameter,and further to obtain a residual signal res and an adaptive codebookcontribution exc_pit. The LSF parameter or the ISF parameter is used torepresent a frequency domain feature of a coefficient (that is, an LPCcoefficient) that is used in the LPC analysis. The residual signal resand the adaptive codebook contribution exc_pit are included in the firsttime domain signal, and the adaptive codebook contribution exc_pit isincluded in the second time domain signal.

Step 212: Obtain a frequency domain signal by performing frequencydomain transformation and processing on the first time domain signal. Asan example, the frequency domain transformation is performed separatelyon the residual signal res and the adaptive codebook contributionexc_pit in the first time domain signal, and then it is determined,according to relevance between a residual signal f_res of a frequencydomain and an adaptive codebook contribution f_exc_pit of the frequencydomain, whether the adaptive codebook contribution contributes to anoutput signal. If the adaptive codebook contribution contributes to theoutput signal, the adaptive codebook contribution f_exc_pit of thefrequency domain is subtracted from the residual signal f_res of thefrequency domain, to obtain a difference signal f_diff of the frequencydomain, and the difference signal f_diff is used as the frequency domainsignal. If the adaptive codebook contribution does not contribute to theoutput signal, the residual signal f_res of the frequency domain isdirectly used as the difference signal f_diff, that is, the frequencydomain signal.

After the frequency domain signal is obtained, the frequency domainsignal is coded using steps 220, 230, and 240 that are the same as steps120, 130, and 140 in FIG. 1, to obtain a coded frequency domain signal.

Step 250: Code the second time domain signal. As an example, step 260 isperformed at the same time when the frequency domain signal is coded.The time domain signal may be coded using any time domain coding method(such as prediction coding or pulse code modulation (PCM) coding), and aused time domain coding method does not constitute a limitation to thepresent disclosure. When the adaptive codebook contribution contributesto the output signal, the adaptive codebook contribution needs to beobtained at a decoding end, and therefore, the adaptive codebookcontribution exc_pit in the second time domain signal is coded, so thatit is transmitted as a bit stream to a receive end. However, if theadaptive codebook contribution does not contribute to the output signal,that is, an output at the decoding end does not require the adaptivecodebook contribution, this part of time domain coding is not required,improving the coding efficiency. That the adaptive codebook contributioncontributes to the output signal means that a high-quality output signalcannot be obtained at the decoding end only according to the codedfrequency domain signal.

Step 260: Multiplex the coded frequency domain signal and the codedsecond time domain signal into the bit stream.

It should be noted that, besides including the difference signal f_diff,the frequency domain signal on which the frequency domain coding needsto be performed may further include another signal, such as a flagindicating whether the adaptive codebook contribution contributes to theoutput signal. Similarly, besides including the adaptive codebookcontribution exc_pit, the second time domain signal on which the timedomain coding needs to be performed may further include otherinformation required for decoding.

In the foregoing time-frequency joint coding that is described withreference to FIG. 2, bit allocation for a frequency domain signal isadjusted according to a highest frequency of the frequency domain signalto which bits are allocated, which is combined with time domain coding,so that a better coding effect is achieved.

FIG. 3 shows a signal decoding method 300 according to an embodiment ofthe present disclosure. The method 300 includes the following steps.

Step 310: Obtain, from a received bit stream, a frequency domain signalobtained by decoding. When only frequency domain coding is used, using afrequency domain decoding method corresponding to a frequency domaincoding method, the frequency domain signal obtained by decoding isobtained from the received bit stream. In the case of time-frequencyjoint coding, the frequency domain signal obtained by decoding isobtained from the received bit stream by performing the followingoperations: performing frequency domain decoding on frequency domaininformation in the bit stream to obtain a first frequency domain signal;determining, according to the first frequency domain signal, whether atime domain coding signal that contributes to an output signal exists inthe bit stream; when it is determined that a time domain coding signalthat contributes to the output signal exists in the bit stream,performing time domain decoding and frequency domain transformation onthe time domain coding signal to obtain a second frequency domainsignal, and synthesizing the first frequency domain signal and thesecond frequency domain signal to obtain the frequency domain signalobtained by decoding. This is further described below in detail withreference to FIG. 4.

Step 320: When the frequency domain signal obtained by decoding meets apredetermined condition, predict, according to the frequency domainsignal obtained by decoding, a frequency domain signal that is notobtained by decoding. As an example, that the frequency domain signalobtained by decoding meets a predetermined condition includes at leastone of the following: a highest frequency of the frequency domain signalobtained by decoding is greater than a predetermined value, and thefrequency domain signal obtained by decoding includes a time domaincoding signal on which the frequency domain transformation is performedand that contributes to an output signal. It should be noted that, inpractice, a determining condition that the frequency domain signalobtained by decoding includes a time domain coding signal on which thefrequency domain transformation is performed and that contributes to anoutput signal may be applied first, and then a determining conditionthat a highest frequency of the frequency domain signal obtained bydecoding is greater than a predetermined value is applied; or an inversesequence is used, or only one of the two may be used.

As described above with reference to step 130 in FIG. 1, thepredetermined value is determined according to the number tot_bit ofpredetermined bits used for the frequency domain coding and a resolutionof the frequency domain signal. According to a requirement of practice,the predetermined value may be set to a frequency value that is acertain frequency less than a value of the highest frequency of thefrequency domain signal. When the frequency domain signal is dividedinto sub-bands, the predetermined value may be an index number of asub-band, and the highest frequency of the frequency domain signal towhich bits are allocated is also represented using an index number of asub-band in which the highest frequency domain is located. A value ofthe predetermined value at a decoding end may be the same as or may bedifferent from a value of the predetermined value at a coding end.

In the case of the time-frequency joint coding, the frequency domainsignal obtained by decoding, which is obtained by decoding the bitstream in step 310, possibly includes the time domain coding signal onwhich the frequency domain transformation is performed and thatcontributes to the output signal, and the time domain coding signal onwhich the frequency domain transformation is performed and thatcontributes to the output signal, for example, is a signal that isobtained by performing the time domain decoding and the frequency domaintransformation on time domain coding information included in the bitstream, such as an adaptive codebook contribution. According todifferent types of coded signals and when a time domain analysis methodused during the coding is not an LPC analysis, the time domain codingsignal on which the frequency domain transformation is performed andthat contributes to the output signal may also be another signal exceptthe adaptive codebook contribution.

When the frequency domain signal obtained by decoding includes theadaptive codebook contribution, it may be learned, according to a flagindicating whether the foregoing adaptive codebook contributioncontributes to the output signal, whether the frequency domain signalobtained by decoding includes the time domain coding signal on which thefrequency domain transformation is performed and that contributes to theoutput signal. The frequency domain signal obtained by decoding includesthe time domain coding signal on which the frequency domaintransformation is performed and that contributes to the output signal,which indicates that a high-quality output is difficult to be obtainedby only relying on the frequency domain decoding, and according to afeature of a speech/audio signal, in this case, simply setting thefrequency domain signal that is not obtained by decoding to noisedeteriorates the quality of the output signal, so that the frequencydomain signal that is not obtained by decoding needs to be predicted.

As an example of predicting, according to the frequency domain signalobtained by decoding, the frequency domain signal that is not obtainedby decoding, a frequency domain signal of a frequency band may beselected from the highest frequency of the frequency domain signalobtained by decoding to a low frequency, and the frequency domain signalthat is not obtained by decoding may be predicted according to theselected frequency domain signal. For example, for a signal whose framelength is 20 ms and sampling rate is 12.8 kHz, there are 256 frequencydomain coefficients, and a bandwidth is 6.4 kHz; when a code rate is 7.6kbps, one sub-band for every 16 coefficients, there are 16 sub-bands intotal, and the predetermined value is set to 10 (4 kHz); and when ahighest frequency band of the frequency domain signal obtained bydecoding is greater than 10, a frequency domain coefficient that is notobtained by decoding in a range of 4 to 6.4 kHz is obtained throughprediction using a frequency domain coefficient that is obtained bydecoding in a range of 1.6 to 4 kHz. As an example of implementation ofthe prediction, the frequency domain signal that is not obtained bydecoding may be predicted by performing normalization processing,envelope processing, and the like on the selected frequency domainsignal. The implementation of the normalization processing and theenvelope processing is a means that is known to a person skilled in theart, and is not described in detail herein. In addition, according to atype of the output signal, a person skilled in the art may predict, byselecting another manner, the frequency domain signal that is notobtained by decoding, for example, may also predict, according to afrequency domain signal in a fixed frequency band in the frequencydomain signal obtained by decoding, the frequency domain signal that isnot obtained by decoding.

It should be noted that, after the frequency domain signal that is notobtained by decoding is obtained according to the frequency domainsignal obtained by decoding, a predicted frequency domain coefficientthat is not obtained by decoding can be corrected using an ISF parameteror an LSF parameter from the coding end, to prevent the predictedfrequency domain signal from including a frequency channel number withexcessive energy. For example, a resonant peak location is estimatedusing the LSF parameter or the ISF parameter; and at each estimatedresonant peak location, a frequency domain coefficient with a greateramplitude is scaled. As an example, when an amplitude of a predictedfrequency domain coefficient near the resonant peak location is greaterthan a threshold (the threshold may be set according to a characteristicof a time domain analysis at the coding end), the amplitude of thepredicted frequency domain coefficient near the resonant peak locationis decreased.

In addition, when the frequency domain signal does not meet thepredetermined condition, the frequency domain signal that is notobtained by decoding is predicted using noise.

Step 330: Obtain, according to the frequency domain signal obtained bydecoding and the predicted frequency domain signal, a time domain signalthat is finally outputted. The frequency domain signal obtained bydecoding is obtained by decoding and the frequency domain signal that isnot obtained by decoding is predicted, so as to obtain frequency domainsignals in an entire frequency band, an output signal in a time domainis obtained by performing processing such as frequency domain inversetransformation, for example, inverse fast Fourier transform (IFFT). Asan example, in the case of the time-frequency joint coding, an LPCcoefficient is obtained by performing transformation on the ISFparameter or the LSF parameter, time domain synthesis is performed,using the LPC coefficient, on a signal obtained after the frequencydomain inverse transformation, to obtain a time domain signal that isfinally outputted. In practice, an engineering technical person in theart knows a solution about how to obtain the output signal in the timedomain according to the frequency domain signal, which is not bedescribed in detail herein.

In the foregoing signal decoding method according to this embodiment ofthe present disclosure, which is described with reference to FIG. 3, afrequency domain signal that is not obtained by decoding is set underthe guidance of a frequency domain signal obtained by decoding, so as toachieve a better effect of an output signal.

To better disclose this embodiment of the present disclosure to a personskilled in the art, the following describes, with reference to FIG. 4,an application of the decoding method according to this embodiment ofthe present disclosure in a time-frequency joint decoding solution. Inthe time-frequency joint decoding solution, except the step ofobtaining, from a received bit stream, a frequency domain signalobtained by decoding (310), subsequent operations are the same as thosein steps 320 and 330 described with reference to FIG. 3. Therefore, thefollowing only describes how to obtain, in a time-frequency jointdecoding method, the frequency domain signal obtained by decoding.

FIG. 4 shows a method 410 for obtaining, from a received bit stream, afrequency domain signal obtained by decoding in a time-frequency jointdecoding method. The method 410 includes the following steps.

Step 411: De-multiplex a bit stream into a first group of bits and asecond group of bits. During decoding at a receive end, when the bitstream is received, the bit stream is de-multiplexed into the firstgroup of bits and the second group of bits using a de-multiplexingtechnology corresponding to a multiplexing technology in step 260 inFIG. 2. The first group of bits includes frequency domain information onwhich the following frequency domain decoding needs to be performed, andthe second group of bits includes a time domain coding signal on whichthe following time domain decoding needs to be performed and thatcontributes to an output signal.

For time domain joint decoding of an audio signal, the first group ofbits, for example, includes a difference signal f_diff, a flagindicating whether an adaptive codebook contribution contributes to anoutput signal, and the like. The second group of bits, for example,includes the adaptive codebook contribution when the adaptive codebookcontribution contributes to the output signal. It should be noted that,when encoding the first group of bits and the second group of bits andsignal, another signal may further be encoded correspondingly.

Step 412: Perform the frequency domain decoding on the first group ofbits to obtain a first frequency domain signal, and determine, accordingto the first frequency domain signal, whether a time domain codingsignal that contributes to the output signal exists in the bit stream.The first group of bits is decoded using a decoding method correspondingto a frequency domain coding method at a coding end, to obtain the firstfrequency domain signal. The first frequency domain signal, for example,includes a decoded difference signal f_diff, and the flag indicatingwhether the adaptive codebook contribution contributes to the outputsignal.

Step 413: Perform the time domain decoding on the second group of bits.The second group of bits is decoded using a decoding methodcorresponding to a time domain coding method at the coding end, toobtain a decoded time domain signal. When it is determined that a timedomain coding signal that contributes to the output signal exists in thebit stream, the time domain decoding is performed on the time domaincoding signal in the second group of bits.

Step 414: Perform frequency domain transformation on the adaptivecodebook contribution in the decoded time domain signal, to obtain asecond frequency domain signal.

Step 415: Synthesize the first frequency domain signal and the secondfrequency domain signal to obtain the frequency domain signal obtainedby decoding. As an example, when the adaptive codebook contributioncontributes to the output signal, the frequency domain signal isobtained through synthesis by adding the difference signal f_diff in thefirst frequency domain signal and the adaptive codebook contribution inthe second frequency domain signal. When the adaptive codebookcontribution does not contribute to the output signal, the differencesignal f_diff in the first frequency domain signal is directly used asthe frequency domain signal.

After the frequency domain signal obtained by decoding is obtained, atime domain signal that is finally outputted is obtained using stepsthat are the same as steps 320 and 330 in FIG. 3.

Associated with the foregoing method embodiments, the present disclosurefurther provides a coding device and a decoding device, where the codingdevice or the decoding device may be located in a terminal device, anetwork device, or a test device. The coding device or the decodingdevice may be implemented by a hardware circuit, or be implemented bysoftware in cooperation with hardware.

FIG. 5 shows exemplary implementation of a coding device and/or adecoding device according to the present disclosure. As shown in FIG. 5,a processor 510 invokes a coding device or decoding device 530 using aninput/output interface 520, and implements coding or decoding processingof an audio signal with assistance of a memory 540. The coding device ordecoding device 530 may perform various methods and procedures in theforegoing method embodiments.

FIG. 6 shows a coding device 600 for signal coding according to anembodiment of the present disclosure. The coding device 600 includes afrequency domain transformation unit 610, which obtains a frequencydomain signal according to an input signal; a bit allocation unit 620,which allocates predetermined bits to the frequency domain signalaccording to a predetermined allocation rule; a bit adjustment unit 630,which adjusts the bit allocation for the frequency domain signal when ahighest frequency of the frequency domain signal to which bits areallocated is greater than or equal to a predetermined value; and afrequency domain coding unit 640, which codes the frequency domainsignal according to the bit allocation that has been adjusted.

The frequency domain transformation unit 610 may obtain the frequencydomain signal according to the input signal. The input signal may be asignal of various types, such as an image signal, a data signal, anaudio signal, a video signal, or a text signal. Frequency domaintransformation may be performed on the input signal using an algorithmsuch as an FFT or a DCT, to obtain the frequency domain signal. The typeof the input signal and the frequency domain transformation algorithm donot constitute a limitation to the present disclosure.

The bit allocation unit 620 may allocate predetermined bits tot_bit tothe frequency domain signal according to a predetermined allocationrule. The tot_bit is the number of bits that need to be used forperforming coding on the frequency domain signal. The predeterminedallocation rule, for example, may be that more bits in the predeterminedbits are allocated to a low frequency band signal in the frequencydomain signal, and rest bits in the predetermined bits are allocated toa frequency band with greater energy except the low frequency bandsignal. For allocation of a frequency domain signal in a low frequencyband, the more bits may be uniformly allocated to the low frequency bandsignal for all low frequency bands or the more bits may be allocated tothe low frequency band signal according to energy distribution of thelow frequency band signal. A reason for allocating the more bits to thelow frequency band signal is that, in a frequency domain, an audiosignal such as a speech is mainly concentrated in a low frequency range,and allocating the more bits to the audio signal can improve theefficiency of frequency domain coding.

As an example, in an exemplary case in which the frequency domain codingis performed on the audio signal, as described above with reference tostep 120 in FIG. 1, a frequency domain signal in a frequency range of 0to 4 kHz is divided into 10 sub-bands, where there are 5 sub-bands in afrequency range of 0 to 2 kHz, and there are 5 sub-bands in a frequencyrange of 2 to 4 kHz. Then, bit allocation is performed for eachsub-band. The more bits whose quantity is 1F_bit are allocated to a lowfrequency domain signal in the frequency range of 0 to 2 kHz. Rest bitsrest_bit (subtracting 1F_bit from the tot_bit) are allocated to thesub-bands in the frequency range of 2 to 4 kHz according to an envelopeof each sub-band in the frequency range of 2 to 4 kHz. The number ofsub-bands to which bits are allocated and a sub-band last_bin of ahighest frequency band to which bits are allocated are determinedaccording to the rest_bits and an envelope size of each sub-band, and atthe same time, a remainder that cannot be exactly divided by 5 is evenlyallocated to each sub-band in the range of 0 to 2 kHz.

The bit adjustment unit 630 may adjust the bit allocation for thefrequency domain signal when the highest frequency of the frequencydomain signal to which bits are allocated is greater than or equal tothe predetermined value B. The predetermined value B is determinedaccording to the bit number tot_bit of the predetermined bits and aresolution (for example, 4 kHz) of the frequency domain signal. Thepredetermined value is a preset upper-limit frequency value. In specificpractice, the predetermined value B may be set to a frequency value thatis a certain frequency less than a value (for example, 4 kHz) of thehighest frequency of the frequency domain signal, for example, set to2.9 kHz, 3.2 kHz, 3.5 kHz, or the like. As described above, when thefrequency domain signal is divided into the sub-bands for coding, thepredetermined value B may be an index number (for example, 7 or 8) of 10sub-bands in a frequency range of 0 to 4 kHz, and at this time, thehighest frequency of the frequency domain signal to which bits areallocated may also be represented using an index number index of asub-band in which the highest frequency is located.

If the highest frequency (for example, index=7) of the frequency domainsignal to which bits are allocated is less than the predetermined value(for example, B=8), the allocation of the predetermined bits that isperformed according to the predetermined allocation rule in the bitallocation unit 620 is maintained.

When the highest frequency is greater than or equal to the predeterminedvalue, the bit adjustment unit 630 may adjust the bit allocation for thefrequency domain signal that is performed, according to thepredetermined allocation rule, by the bit allocation unit 620. Accordingto the type of the input signal, a frequency domain characteristic ofthe frequency domain signal, or the like, a part that contributes lessto an output at a decoding end in the frequency domain signal may bereduced, and bits allocated to the highest frequency to which bits areallocated and its nearby frequency domain signal may accordingly beincreased. As an example, the bit adjustment unit 630 may reduce thenumber of bits allocated to a frequency band to which more bits areallocated in the frequency domain signal, and increase the number ofbits allocated to the highest frequency to which bits are allocated andits nearby frequency domain signal. For an audio signal, the frequencyband to which more bits are allocated is a low frequency band of 0 to 2kHz.

For implementation of adjusting the bit allocation for the frequencydomain signal, reference may be made to the adjustment examples 1 to 3that are described above, which are not be described in detail hereinagain.

The frequency domain coding unit 640 codes the frequency domain signalaccording to the bit allocation that has been adjusted. A method forcoding the frequency domain signal, for example, may be transformationcoding, sub-band coding, or the like. In addition, when the highestfrequency is less than the predetermined value, the bit adjustment unit630 does not adjust the bit allocation for the frequency domain signal.In this case, the bit allocation for the frequency domain signal is bitallocation that is performed according to a predetermined bit allocationrule, and the frequency domain coding unit 640 codes the frequencydomain signal according to the bit allocation that is performedaccording to the predetermined bit allocation rule.

In the foregoing device 600 for signal coding, bit allocation for afrequency domain signal is adjusted according to a highest frequency ofthe frequency domain signal to which bits are allocated, so that abetter coding effect is achieved.

The coding device 600 may be properly applied to various codingtechnologies, and the following uses an application of the device intime-frequency joint coding as an example for exemplary description.

FIG. 7 shows a time-frequency joint coding device 700 using a codingdevice in an embodiment of the present disclosure.

The time-frequency joint coding device 700 includes a time domainanalysis unit 711, which obtains a first time domain signal and a secondtime domain signal by performing a time domain analysis on an inputsignal; a frequency domain transformation unit 712, which obtains afrequency domain signal by performing frequency domain transformationand processing on the first time domain signal; a bit allocation unit720, which allocates predetermined bits to the frequency domain signalaccording to a predetermined allocation rule; a bit adjustment unit 730,which adjusts the bit allocation for the frequency domain signal when ahighest frequency of the frequency domain signal to which bits areallocated is greater than or equal to a predetermined value; a frequencydomain coding unit 740, which codes the frequency domain signalaccording to the bit allocation that has been adjusted; a time domaincoding unit 750, which codes the second time domain signal; and a bitmultiplexing unit 760, which multiplexes a coded frequency domain signaland a coded second time domain signal into a bit stream.

The bit allocation unit 720, the bit adjustment unit 730, and thefrequency domain coding unit 740 in FIG. 7 are respectively the same asthe bit allocation unit 620, the bit adjustment unit 630, and thefrequency domain coding unit 640 in FIG. 6. Differences between FIG. 7and FIG. 6 lie in that, the time domain coding unit 750 and the bitmultiplexing unit 760 are added, and the frequency domain transformationunit 610 in FIG. 6 is replaced by the time domain analysis unit 711 andthe frequency domain transformation unit 712. The following describesthe differences between FIG. 7 and FIG. 6, and does not describe thecontent in common again.

The time domain analysis unit 711 obtains the first time domain signaland the second time domain signal by performing the time domain analysison the input signal. For example, an LPC analysis and processing areperformed on the input signal to obtain an ISF parameter (or an LSFparameter), a residual signal res, and an adaptive codebook contributionexc_pit. The residual signal res and the adaptive codebook contributionexc_pit are used as the first time domain signal, and the adaptivecodebook contribution exc_pit is used as the second time domain signal.

The frequency domain transformation unit 712 may obtain the frequencydomain signal by performing the frequency domain transformation andprocessing on the first time domain signal. As an example, the frequencydomain transformation is performed separately on the residual signal resand the adaptive codebook contribution exc_pit in the first time domainsignal, and then it is determined, according to relevance between aresidual signal f_res of a frequency domain and an adaptive codebookcontribution f_exc_pit of the frequency domain, whether the adaptivecodebook contribution contributes to an output signal. If the adaptivecodebook contribution contributes to the output signal, the adaptivecodebook contribution f_exc_pit of the frequency domain is subtractedfrom the residual signal f_res of the frequency domain, to obtain adifference signal f_diff of the frequency domain, and the differencesignal f_diff is included in the frequency domain signal. If theadaptive codebook contribution does not contribute to the output signal,the residual signal f_res of the frequency domain is directly used asthe difference signal f_diff and is transmitted as the frequency domainsignal. Besides including the difference signal f_diff, the frequencydomain signal may further include another signal, for example, a flagindicating whether the adaptive codebook contribution contributes to theoutput signal.

After the frequency domain signal is obtained, the frequency domainsignal is coded using the bit allocation unit 720, the bit adjustmentunit 730, and the frequency domain coding unit 740 in FIG. 7, to obtaina coded frequency domain signal.

The time domain coding unit 750 may code the second time domain signal.The time domain signal may be coded using a time domain coding methodsuch as prediction coding or pulse code modulation. When the adaptivecodebook contribution contributes to the output signal, the adaptivecodebook contribution needs to be obtained at a decoding end, andtherefore, the adaptive codebook contribution exc_pit in the second timedomain signal is coded, so that it is transmitted to a receive end.However, if the adaptive codebook contribution does not contribute tothe output signal, the adaptive codebook contribution does not need tobe coded and transmitted, improving the coding efficiency. The bitmultiplexing unit 760 may multiplex the coded frequency domain signaland the coded second time domain signal into the bit stream.

In the foregoing time-frequency joint coding device that is describedwith reference to FIG. 7, bit allocation for a frequency domain signalis adjusted according to a highest frequency of the frequency domainsignal to which bits are allocated, which is combined with time domaincoding, so that a better coding effect is achieved.

FIG. 8 shows a decoding device 800 for signal decoding according to anembodiment of the present disclosure. The decoding device 800 includes adecoding unit 810, which obtains, from a received bit stream, afrequency domain signal obtained by decoding; a bandwidth extension unit820 configured to predict a frequency domain signal that is not obtainedby decoding, and when the frequency domain signal obtained by decodingmeets a predetermined condition, predict, according to the frequencydomain signal obtained by decoding, the frequency domain signal that isnot obtained by decoding; and an output unit 830, which obtains,according to the frequency domain signal obtained by decoding and thepredicted frequency domain signal, a time domain signal that is finallyoutputted.

The decoding unit 810 may obtain, from the received bit stream, thefrequency domain signal obtained by decoding. When only frequency domaincoding is used, using a frequency domain decoding method correspondingto a frequency domain coding method, the frequency domain signalobtained by decoding is obtained from the received bit stream. In thecase of time-frequency joint coding, the decoding unit 810 may obtain,from the received bit stream by performing the following operations, thefrequency domain signal obtained by decoding; performing frequencydomain decoding on frequency domain information in the bit stream toobtain a first frequency domain signal; determining, according to thefirst frequency domain signal, whether a time domain coding signal thatcontributes to an output signal exists in the bit stream; when it isdetermined that a time domain coding signal that contributes to theoutput signal exists in the bit stream, performing time domain decodingand frequency domain transformation on the time domain coding signal toobtain a second frequency domain signal, and synthesizing the firstfrequency domain signal and the second frequency domain signal to obtainthe frequency domain signal obtained by decoding. This is describedbelow in detail with reference to FIG. 9.

The bandwidth extension unit 820 may be configured to predict thefrequency domain signal that is not obtained by decoding. When thefrequency domain signal obtained by decoding meets the predeterminedcondition, the bandwidth extension unit 820 may predict, according tothe frequency domain signal obtained by decoding, the frequency domainsignal that is not obtained by decoding. As an example, that thefrequency domain signal obtained by decoding meets a predeterminedcondition includes at least one of the following: a highest frequency ofthe frequency domain signal obtained by decoding is greater than apredetermined value, and the frequency domain signal obtained bydecoding includes a time domain coding signal on which the frequencydomain transformation is performed and that contributes to the outputsignal. In practice, selection may be performed according to a need.

As described above, the predetermined value may be determined accordingto the number tot_bit of predetermined bits used for the frequencydomain coding and a resolution of the frequency domain signal. Accordingto a need of practice, the predetermined value may be set to a frequencyvalue that is a certain frequency less than a value of the highestfrequency of the frequency domain signal. When the frequency domainsignal is divided into sub-bands, the predetermined value may be anindex number of a sub-band, and the highest frequency of the frequencydomain signal to which bits are allocated is also represented using anindex number of a sub-band in which the highest frequency domain islocated.

When a time-frequency joint decoding technology is used, the frequencydomain signal obtained by decoding, which is obtained by the decodingunit 810 by decoding the bit stream, possibly includes a signal that isobtained by performing the time domain decoding and the frequency domaintransformation on time domain information included in the bit stream,for example, an adaptive codebook contribution. It may be learned,according to a flag indicating whether the foregoing adaptive codebookcontribution contributes to the output signal, whether the frequencydomain signal includes the time domain coding signal on which thefrequency domain transformation is performed and that contributes to theoutput signal. According to different types of coded signals and when atime domain analysis method used during the coding is not an LPCanalysis, the time domain coding signal on which the frequency domaintransformation is performed and that contributes to the output signalmay also be another signal.

The frequency domain signal obtained by decoding includes the signalthat is obtained by performing the time domain decoding and thefrequency domain transformation on the time domain information includedin the bit stream, which indicates that the frequency domain signal thatis not obtained by decoding includes information that is useful to anoutput, so that the frequency domain signal that is not obtained bydecoding needs to be predicted, and simply setting the frequency domainsignal that is not obtained by decoding to noise deteriorates thequality of an output signal.

In addition, when the frequency domain signal obtained by decoding doesnot meet the predetermined condition, the bandwidth extension unit 820may set the frequency domain signal that is not obtained by decoding tothe noise.

As an example of predicting, according to the frequency domain signalobtained by decoding, the frequency domain signal that is not obtainedby decoding, the bandwidth extension unit 820 may select a frequencydomain signal of a frequency band from the highest frequency of thefrequency domain signal obtained by decoding to a low frequency, andprocess the selected frequency domain signal as described above, so asto predict, according to the selected frequency domain signal, thefrequency domain signal that is not obtained by decoding. In addition,the frequency domain signal that is not obtained by decoding may also bepredicted using another manner, for example, the frequency domain signalthat is not obtained by decoding may also be predicted according to afrequency domain signal in a fixed frequency band in the frequencydomain signal obtained by decoding.

The output unit 830 may obtain, according to the frequency domain signalobtained by decoding and the predicted frequency domain signal, the timedomain signal that is finally outputted. After the frequency domainsignal that is not obtained by decoding is predicted, frequency domainsignals in an entire frequency band are obtained, and frequency domaininverse transformation is performed on frequency domain signals in anentire bandwidth using inverse transformation of the frequency domaintransformation used during the coding, so that an output signal in atime domain is obtained. As described above, the output unit may performa time domain synthesis, using an LPC coefficient that is obtainedaccording to an ISF parameter (or an LSF parameter), on a signal afterthe frequency domain inverse transformation, to obtain the time domainsignal that is finally outputted for outputting.

For more detailed operations of the units in the decoding device 800,reference may be made to the foregoing steps that are described withreference to FIG. 3.

In the foregoing the decoding device 800 for signal decoding accordingto this embodiment of the present disclosure, which is described withreference to FIG. 8, a frequency domain signal that is not obtained bydecoding is set under the guidance of a frequency domain signal obtainedby decoding, so as to make an output signal achieves a better effect.

To better disclose this embodiment of the present disclosure to a personskilled in the art, the following briefly describes an application ofthe decoding device according to this embodiment of the presentdisclosure in a time-frequency joint decoding solution. In thetime-frequency joint decoding solution, except the operations of thedecoding unit 810, operations of other composition units are the same asthe operations of the bandwidth extension unit 820 and the output unit830. Therefore, the following only describes specific implementation ofthe decoding unit 810 in a time-frequency joint decoding method.

FIG. 9 shows a block diagram of a decoding unit 910 in time-frequencyjoint decoding. The decoding unit 910 includes a de-multiplexing unit911, which de-multiplexes a bit stream into a first group of bits and asecond group of bits; a frequency domain decoding unit 912, whichperforms frequency domain decoding on the first group of bits to obtaina first frequency domain signal, and determines, according to the firstfrequency domain signal, whether a time domain coding signal thatcontributes to an output signal exists in the bit stream; a time domaindecoding unit 913, which performs time domain decoding in the secondgroup of bits if it is determined that a time domain coding signal thatcontributes to the output signal exists in the bit stream; a frequencydomain transformation unit 914, which performs frequency domaintransformation on a decoded time domain signal to obtain a secondfrequency domain signal; and a synthesis unit 915, which synthesizes thefirst frequency domain signal and the second frequency domain signal toobtain a frequency domain signal obtained by decoding.

For the purpose of convenient and brief description, for specificoperations of the de-multiplexing unit 911, the frequency domaindecoding unit 912, the time domain decoding unit 913, the frequencydomain transformation unit 914, or the synthesis unit 915, refer to 411,412, 413, 414, and 415 in FIG. 4, which are not be described in detailherein again.

A person of ordinary skill in the art may be aware that, in combinationwith the examples described in the embodiments disclosed in thisspecification, units and algorithm steps may be implemented byelectronic hardware or a combination of computer software and electronichardware. Whether the functions are performed by hardware or softwaredepends on particular applications and design constraint conditions ofthe technical solutions. A person skilled in the art may use differentmethods to implement the described functions for each particularapplication, but it should not be considered that the implementationgoes beyond the scope of the present disclosure.

In the several embodiments provided in the present application, itshould be understood that the disclosed device and method may beimplemented in other manners. For example, the described deviceembodiment is merely exemplary. For example, the unit division is merelylogical function division and may be other division in actualimplementation. For example, multiple units or components may becombined or integrated into another system, or some features may beignored or not performed.

The units described as separate parts may or may not be physicallyseparate, may be located in one position, or may be distributed onmultiple network units. A part or all of the units may be selected asrequired to achieve objectives of the solutions of the embodiments.

In addition, functional units in the embodiments of the presentdisclosure may be integrated into one processing unit, or each of theunits may exist alone physically, or two or more units may be integratedinto one unit.

When the functions are implemented in a form of a software functionalunit and sold or used as an independent product, the functions may bestored in a computer-readable storage medium. Based on such anunderstanding, the technical solutions of the present disclosureessentially, or the part contributing to the prior art, or a part of thetechnical solutions may be implemented in a form of a software product.The computer software product is stored in a storage medium, andincludes several instructions for instructing a computer device (whichmay be a personal computer, a server, a network device, or the like) toperform all or a part of the steps of the methods described in theembodiments of the present disclosure. The foregoing storage mediumincludes any medium that can store program code, such as a universalserial bus (USB) flash drive, a removable hard disk, a read-only memory(ROM), a random access memory (RAM), a magnetic disk, or an opticaldisc.

The foregoing descriptions are merely specific implementation manners ofthe present disclosure, but are not intended to limit the protectionscope of the present disclosure. Any variation or replacement readilyfigured out by a person skilled in the art within the technical scopedisclosed in the present disclosure shall fall within the protectionscope of the present disclosure. Therefore, the protection scope of thepresent disclosure shall be subject to the protection scope of theclaims.

What is claimed is:
 1. An audio signal decoding method performed by adecoder comprising a processor, wherein the method comprises: decoding areceived bitstream to obtain a decoded frequency domain signal of acurrent frame of the audio signal; predicting an un-decoded frequencydomain signal of the current frame according to the decoded frequencydomain signal of the current frame when the decoded frequency domainsignal meets a given condition; and obtaining a time domain signal ofthe current frame according to the decoded frequency domain signal andthe predicted frequency domain signal.
 2. The method according to claim1, wherein the given condition comprises a highest index of a sub-bandof the decoded frequency domain signal is greater than a threshold. 3.The method according to claim 1, wherein the given condition comprisesthe decoded frequency domain signal comprises a time domain codingsignal which contributes to an output signal.
 4. The method according toclaim 1, wherein decoding the received bitstream to obtain the decodedfrequency domain signal of the current frame of the audio signalcomprises: performing frequency domain decoding on frequency domaininformation in the received bitstream to obtain a first frequency domainsignal; determining whether a time domain coding signal that contributesto an output signal exists in the received bitstream according to thefirst frequency domain signal; performing time domain decoding andfrequency domain transformation on the time domain coding signal toobtain a second frequency domain signal when it is determined that atime domain coding signal that contributes to the output signal existsin the received bitstream; and synthesizing the first frequency domainsignal and the second frequency domain signal to obtain the decodedfrequency domain signal.
 5. The method according to claim 2, wherein thethreshold is determined according to a number of bits used for frequencydomain coding and a resolution of the decoded frequency domain signal.6. The method according to claim 1, wherein predicting the un-decodedfrequency domain signal of the current frame according to the decodedfrequency domain signal of the current frame comprises: selecting afrequency domain signal from the decoded frequency domain signal; andpredicting the un-decoded frequency domain signal of the current frameaccording to the selected frequency domain signal.
 7. The methodaccording to claim 1, wherein predicting the un-decoded frequency domainsignal of the current frame according to the decoded frequency domainsignal of the current frame comprises: estimating a position of aformant of the frequency domain signal of the current frame according toline spectral frequency (LSF) parameters of the current frame; anddecreasing an amplitude of a predicted frequency domain coefficient of asub-band near the formant when the amplitude of the predicted frequencydomain coefficient of the sub-band near the formant is greater than athreshold.
 8. The method according to claim 1, wherein predicting theun-decoded frequency domain signal of the current frame according to thedecoded frequency domain signal of the current frame comprises:estimating a position of a formant of the frequency domain signal of thecurrent frame according to immittance spectral frequency (ISF)parameters of the current frame; and decreasing an amplitude of apredicted frequency domain coefficient of a sub-band near the formantwhen the amplitude of the predicted frequency domain coefficient of thesub-band near the formant is greater than a threshold.
 9. The methodaccording to claim 1, the method further comprises filling theun-decoded frequency domain signal of the current frame with noise whenthe frequency domain signal obtained by decoding does not meet the givencondition.
 10. The method according to claim 1, wherein each sub-band ofthe current frame comprises 16 frequency domain coefficients.
 11. Anaudio signal decoding device, comprising: a processor; and anon-transitory computer readable storage medium storing computerexecutable instructions, wherein the processor being configured toexecute the computer executable instructions to: decode a receivedbitstream to obtain a decoded frequency domain signal of a current frameof the audio signal; predict an un-decoded frequency domain signal ofthe current frame according to the decoded frequency domain signal ofthe current frame when the decoded frequency domain signal meets a givencondition; and obtain a time domain signal of the current frameaccording to the decoded frequency domain signal and the predictedfrequency domain signal.
 12. The device according to claim 11, whereinthe given condition comprises a highest index of a sub-band of thedecoded frequency domain signal is greater than a threshold.
 13. Thedevice according to claim 11, wherein the given condition comprises thedecoded frequency domain signal comprises a time domain coding signalwhich contributes to an output signal.
 14. The device according to claim11, wherein the processor decodes the received bitstream to obtain adecoded frequency domain signal of a current frame of the audio signalby executing the computer executable instructions to: perform frequencydomain decoding on frequency domain information in the receivedbitstream to obtain a first frequency domain signal; determine whether atime domain coding signal that contributes to an output signal exists inthe received bitstream according to the first frequency domain signal;perform time domain decoding and frequency domain transformation on thetime domain coding signal to obtain a second frequency domain signalwhen it is determined that a time domain coding signal that contributesto the output signal exists in the received bitstream; and synthesizethe first frequency domain signal and the second frequency domain signalto obtain the decoded frequency domain signal.
 15. The device accordingto claim 12, wherein the threshold is determined according to a numberof bits used for frequency domain coding and a resolution of the decodedfrequency domain signal.
 16. The device according to claim 11, whereinthe processor predicts the un-decoded frequency domain signal of thecurrent frame according to the decoded frequency domain signal of thecurrent frame by executing the computer executable instructions to:select a frequency domain signal from the decoded frequency domainsignal; and predict the un-decoded frequency domain signal of thecurrent frame according to the selected frequency domain signal.
 17. Thedevice according to claim 11, wherein the processor predicts theun-decoded frequency domain signal of the current frame according to thedecoded frequency domain signal of the current frame by executing thecomputer executable instructions to: estimate a position of a formant ofthe frequency domain signal of the current frame according to linespectral frequency, LSF, parameters of the current frame; and decreasean amplitude of a predicted frequency domain coefficient of a sub-bandnear the formant when the amplitude of the predicted frequency domaincoefficient of the sub-band near the formant is greater than athreshold.
 18. The device according to claim 11, wherein the processorpredicts the un-decoded frequency domain signal of the current frameaccording to the decoded frequency domain signal of the current frame byexecuting the computer executable instructions to: estimate a positionof a formant of the frequency domain signal of the current frameaccording to immittance spectral frequency (ISF) parameters of thecurrent frame; and decrease an amplitude of a predicted frequency domaincoefficient of a sub-band near the formant when the amplitude of thepredicted frequency domain coefficient of the sub-band near the formantis greater than a threshold.
 19. The device according to claim 11, theprocessor is further configured to execute the computer executableinstructions to fill the un-decoded frequency domain signal of thecurrent frame with noise when the frequency domain signal obtained bydecoding does not meet the given condition.
 20. The device according toclaim 11, wherein each sub-band of the current frame comprises 16frequency domain coefficients.